//
//  Const.h
//  didihaha
//
//  Created by 赵忠鹏 on 2017/8/3.
//  Copyright © 2017年 zhaozhongpeng. All rights reserved.
//

#ifndef Const_h
#define Const_h


// 机型判断
#define iPhone4s kScreenHeight<=480
#define iPhone5 ((kScreenHeight<=568) && (kScreenHeight>480))
#define iPhone6   ((kScreenHeight > 568) && (kScreenHeight <= 667))
#define iPhone6P  kScreenHeight > 667

// 系统判断
#define IOS10 ([[[UIDevice currentDevice] systemVersion] doubleValue] >= 10.0)
#define IOS8_9 ([[[UIDevice currentDevice] systemVersion] doubleValue] >= 8.0 && [[UIDevice currentDevice].systemVersion doubleValue] < 10.0)
#define IOS8 ([[[UIDevice currentDevice] systemVersion] doubleValue] >= 8.0 && [[UIDevice currentDevice].systemVersion doubleValue] < 9.0)
//系统大于等于iOS9
#define IOS9 ([[UIDevice currentDevice].systemVersion doubleValue] >= 9.0)


#pragma mark - UI

#define kColor(r,g,b,a) [UIColor colorWithRed:(r/255.0f) green:(g/255.0f) blue:(b/255.0f) alpha:a]
// 屏幕高度
#define kScreenHeight [UIScreen mainScreen].bounds.size.height
// 屏幕宽度
#define kScreenWidth [UIScreen mainScreen].bounds.size.width
// 主屏幕的高度比例
#define kScreen_H_Scale (kScreenHeight/667)
// 主屏幕的宽度比例
#define kScreen_W_Scale (kScreenWidth/375)


#endif /* Const_h */
